package cn.com.nes.site.controller.project.vo;

import cn.com.nes.site.entity.bo.project.ProjectServiceUserAuthPageBO;
import cn.com.nes.site.entity.vo.PageVO;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.springframework.beans.BeanUtils;

import javax.validation.constraints.NotNull;

@ApiModel(parent = PageVO.class)
@Data
public class ProjectServiceUserPageVO extends PageVO {

    @ApiModelProperty(value = "项目ID", required = true)
    @NotNull(message = "项目")
    private String projectUuid;

    @ApiModelProperty(value = "部门ID")
    private String departmentId;

    @ApiModelProperty(value = "服务人员名称")
    private String serviceUserName;

    @ApiModelProperty(value = "服务人员手机号")
    private String serviceUserPhone;

    @ApiModelProperty(value = "服务区域行政区划代码")
    private String serviceAreaCode;

    @ApiModelProperty(value = "启用标识 0-启用 1-禁用", allowableValues = "0,1", allowEmptyValue = true)
    private Integer enableIdentity;

    @ApiModelProperty(value = "服务人员类别 0-施工人员，1-施工负责人", allowableValues = "0,1", allowEmptyValue = true)
    private Integer serviceUserType;

    public ProjectServiceUserAuthPageBO convertToBo() {
        ProjectServiceUserAuthPageBO bo = new ProjectServiceUserAuthPageBO();
        BeanUtils.copyProperties(this, bo);
        return bo;
    }

}
